
import { createApp } from 'vue'

import ElementPlus, { ElMessageBox } from 'element-plus'
import locale from 'element-plus/es/locale/lang/zh-cn'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

import App from '@/App.vue'
import router from '@/router'

import 'default-passive-events'
import 'element-plus/dist/index.css'
import "prismjs/themes/prism.css";

const app = createApp(App)

// 全局注册组件

app.use(ElementPlus, { locale })

for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}

app.config.globalProperties.$confirm = ElMessageBox.confirm

app.use(router).mount('#app')
